package Com.amit.corejava;

class Animal
{
	public void eat()
	{
		System.out.println("Animal is eating");
	}
}

class Dog extends Animal
{
	public void eat()
	{
		System.out.println("Dog is eating");
	}
}
public class BabyDog extends Dog {
	
	public static void main(String[] args) {
		
		Animal a3=new BabyDog();
		
		a3.eat();
		
	}

}
